<?php


namespace app\badmin\model;


use app\common\model\BaseModel;

class HouseType extends BaseModel {

    public static function getList() {
        $data = db('house_type')
            ->field('id,name')
            ->select();
        foreach ($data as $k => $v) {
            $data[$k]['key'] = $v['id'];
            $data[$k]['value'] = $v['name'];
            unset($data[$k]['id']);
            unset($data[$k]['name']);
        }
        return $data;
    }

}